<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org">
<head>
    <th:block th:include="include :: header('新增账号分类配置')"/>
    <th:block th:include="include :: datetimepicker-css"/>
</head>
<body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
    <form class="form-horizontal m" id="form-account-add">
        <div class="form-group">
            <label class="col-sm-3 control-label">分类ID：</label>
            <div class="col-sm-8">
                <input class="form-control" name="cateId" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">分类名称：</label>
            <div class="col-sm-8">
                <input class="form-control" name="cateName" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">状态：</label>
            <div class="col-sm-8">
                <div class="radio-box" th:each="dict : ${@dict.getType('biz_data_state')}">
                    <input name="dataState" th:checked="${dict.default}" th:id="${'dataState_' + dict.dictCode}"
                           th:value="${dict.dictValue}" type="radio">
                    <label th:for="${'dataState_' + dict.dictCode}" th:text="${dict.dictLabel}"></label>
                </div>
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">平台：</label>
            <div class="col-sm-8">
                <select class="form-control m-b" name="platform"
                        th:with="type=${@dict.getType('biz_account_platform')}">
                    <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
                </select>
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">公众号：</label>
            <div class="col-sm-8">
                <input class="form-control" name="name" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">微信号：</label>
            <div class="col-sm-8">
                <input class="form-control" name="wxAlias" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">wx biz：</label>
            <div class="col-sm-8">
                <input class="form-control" name="wxBiz" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">wx origin id：</label>
            <div class="col-sm-8">
                <input class="form-control" name="wxOriginId" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">头像：</label>
            <div class="col-sm-8">
                <input class="form-control" name="avatar" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">二维码：</label>
            <div class="col-sm-8">
                <input class="form-control" name="qrcode" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">预估粉丝数：</label>
            <div class="col-sm-8">
                <input class="form-control" name="fansNumEstimate" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">描述：</label>
            <div class="col-sm-8">
                <textarea class="form-control" name="description"></textarea>
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">总排名：</label>
            <div class="col-sm-8">
                <input class="form-control" name="rank" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">分类排名：</label>
            <div class="col-sm-8">
                <input class="form-control" name="cateRank" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">发布次数：</label>
            <div class="col-sm-8">
                <input class="form-control" name="pushTotal" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">篇数：</label>
            <div class="col-sm-8">
                <input class="form-control" name="articlesTotal" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">总阅读数：</label>
            <div class="col-sm-8">
                <input class="form-control" name="readNumTotal" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">平均阅读数：</label>
            <div class="col-sm-8">
                <input class="form-control" name="avgReadNum" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">头条：</label>
            <div class="col-sm-8">
                <input class="form-control" name="topReadNumAvg" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">头条：</label>
            <div class="col-sm-8">
                <input class="form-control" name="topLikeNumAvg" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">单篇最大阅读数：</label>
            <div class="col-sm-8">
                <input class="form-control" name="readNumMax" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">平均在看数：</label>
            <div class="col-sm-8">
                <input class="form-control" name="avgLikeNum" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">评分数：</label>
            <div class="col-sm-8">
                <input class="form-control" name="indexScores" type="text">
            </div>
        </div>
        <div class="form-group">
            <label class="col-sm-3 control-label">统计时间：</label>
            <div class="col-sm-8">
                <div class="input-group date">
                    <input class="form-control" name="statTime" placeholder="yyyy-MM-dd" type="text">
                    <span class="input-group-addon"><i class="fa fa-calendar"></i></span>
                </div>
            </div>
        </div>
    </form>
</div>
<th:block th:include="include :: footer"/>
<th:block th:include="include :: datetimepicker-js"/>
<script th:inline="javascript">
    var prefix = ctx + "cms/account"
    $("#form-account-add").validate({
        focusCleanup: true
    });

    function submitHandler() {
        if ($.validate.form()) {
            $.operate.save(prefix + "/add", $('#form-account-add').serialize());
        }
    }

    $("input[name='statTime']").datetimepicker({
        format: "yyyy-mm-dd",
        minView: "month",
        autoclose: true
    });
</script>
</body>
</html>